Optimal. Leaf size=70 \[ -\frac {6 d^3 \cos (a+b x)}{b^4}-\frac {6 d^2 (c+d x) \sin (a+b x)}{b^3}+\frac {3 d (c+d x)^2 \cos (a+b x)}{b^2}+\frac {(c+d x)^3 \sin (a+b x)}{b} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.07, antiderivative size = 70, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 2, integrand size = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.143, Rules used = {3296, 2638} \[ -\frac {6 d^2 (c+d x) \sin (a+b x)}{b^3}+\frac {3 d (c+d x)^2 \cos (a+b x)}{b^2}-\frac {6 d^3 \cos (a+b x)}{b^4}+\frac {(c+d x)^3 \sin (a+b x)}{b} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2638
Rule 3296
Rubi steps
\begin {align*} \int (c+d x)^3 \cos (a+b x) \, dx &=\frac {(c+d x)^3 \sin (a+b x)}{b}-\frac {(3 d) \int (c+d x)^2 \sin (a+b x) \, dx}{b}\\ &=\frac {3 d (c+d x)^2 \cos (a+b x)}{b^2}+\frac {(c+d x)^3 \sin (a+b x)}{b}-\frac {\left (6 d^2\right ) \int (c+d x) \cos (a+b x) \, dx}{b^2}\\ &=\frac {3 d (c+d x)^2 \cos (a+b x)}{b^2}-\frac {6 d^2 (c+d x) \sin (a+b x)}{b^3}+\frac {(c+d x)^3 \sin (a+b x)}{b}+\frac {\left (6 d^3\right ) \int \sin (a+b x) \, dx}{b^3}\\ &=-\frac {6 d^3 \cos (a+b x)}{b^4}+\frac {3 d (c+d x)^2 \cos (a+b x)}{b^2}-\frac {6 d^2 (c+d x) \sin (a+b x)}{b^3}+\frac {(c+d x)^3 \sin (a+b x)}{b}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.23, size = 61, normalized size = 0.87 \[ \frac {b (c+d x) \sin (a+b x) \left (b^2 (c+d x)^2-6 d^2\right )+3 d \cos (a+b x) \left (b^2 (c+d x)^2-2 d^2\right )}{b^4} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.77, size = 109, normalized size = 1.56 \[ \frac {3 \, {\left (b^{2} d^{3} x^{2} + 2 \, b^{2} c d^{2} x + b^{2} c^{2} d - 2 \, d^{3}\right )} \cos \left (b x + a\right ) + {\left (b^{3} d^{3} x^{3} + 3 \, b^{3} c d^{2} x^{2} + b^{3} c^{3} - 6 \, b c d^{2} + 3 \, {\left (b^{3} c^{2} d - 2 \, b d^{3}\right )} x\right )} \sin \left (b x + a\right )}{b^{4}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.47, size = 110, normalized size = 1.57 \[ \frac {3 \, {\left (b^{2} d^{3} x^{2} + 2 \, b^{2} c d^{2} x + b^{2} c^{2} d - 2 \, d^{3}\right )} \cos \left (b x + a\right )}{b^{4}} + \frac {{\left (b^{3} d^{3} x^{3} + 3 \, b^{3} c d^{2} x^{2} + 3 \, b^{3} c^{2} d x + b^{3} c^{3} - 6 \, b d^{3} x - 6 \, b c d^{2}\right )} \sin \left (b x + a\right )}{b^{4}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [B] time = 0.03, size = 302, normalized size = 4.31 \[ \frac {\frac {d^{3} \left (\left (b x +a \right )^{3} \sin \left (b x +a \right )+3 \left (b x +a \right )^{2} \cos \left (b x +a \right )-6 \cos \left (b x +a \right )-6 \left (b x +a \right ) \sin \left (b x +a \right )\right )}{b^{3}}-\frac {3 a \,d^{3} \left (\left (b x +a \right )^{2} \sin \left (b x +a \right )-2 \sin \left (b x +a \right )+2 \left (b x +a \right ) \cos \left (b x +a \right )\right )}{b^{3}}+\frac {3 c \,d^{2} \left (\left (b x +a \right )^{2} \sin \left (b x +a \right )-2 \sin \left (b x +a \right )+2 \left (b x +a \right ) \cos \left (b x +a \right )\right )}{b^{2}}+\frac {3 a^{2} d^{3} \left (\cos \left (b x +a \right )+\left (b x +a \right ) \sin \left (b x +a \right )\right )}{b^{3}}-\frac {6 a c \,d^{2} \left (\cos \left (b x +a \right )+\left (b x +a \right ) \sin \left (b x +a \right )\right )}{b^{2}}+\frac {3 c^{2} d \left (\cos \left (b x +a \right )+\left (b x +a \right ) \sin \left (b x +a \right )\right )}{b}-\frac {a^{3} d^{3} \sin \left (b x +a \right )}{b^{3}}+\frac {3 a^{2} c \,d^{2} \sin \left (b x +a \right )}{b^{2}}-\frac {3 a \,c^{2} d \sin \left (b x +a \right )}{b}+c^{3} \sin \left (b x +a \right )}{b} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [B] time = 0.83, size = 278, normalized size = 3.97 \[ \frac {c^{3} \sin \left (b x + a\right ) - \frac {3 \, a c^{2} d \sin \left (b x + a\right )}{b} + \frac {3 \, a^{2} c d^{2} \sin \left (b x + a\right )}{b^{2}} - \frac {a^{3} d^{3} \sin \left (b x + a\right )}{b^{3}} + \frac {3 \, {\left ({\left (b x + a\right )} \sin \left (b x + a\right ) + \cos \left (b x + a\right )\right )} c^{2} d}{b} - \frac {6 \, {\left ({\left (b x + a\right )} \sin \left (b x + a\right ) + \cos \left (b x + a\right )\right )} a c d^{2}}{b^{2}} + \frac {3 \, {\left ({\left (b x + a\right )} \sin \left (b x + a\right ) + \cos \left (b x + a\right )\right )} a^{2} d^{3}}{b^{3}} + \frac {3 \, {\left (2 \, {\left (b x + a\right )} \cos \left (b x + a\right ) + {\left ({\left (b x + a\right )}^{2} - 2\right )} \sin \left (b x + a\right )\right )} c d^{2}}{b^{2}} - \frac {3 \, {\left (2 \, {\left (b x + a\right )} \cos \left (b x + a\right ) + {\left ({\left (b x + a\right )}^{2} - 2\right )} \sin \left (b x + a\right )\right )} a d^{3}}{b^{3}} + \frac {{\left (3 \, {\left ({\left (b x + a\right )}^{2} - 2\right )} \cos \left (b x + a\right ) + {\left ({\left (b x + a\right )}^{3} - 6 \, b x - 6 \, a\right )} \sin \left (b x + a\right )\right )} d^{3}}{b^{3}}}{b} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.29, size = 147, normalized size = 2.10 \[ \frac {3\,d^3\,x^2\,\cos \left (a+b\,x\right )}{b^2}-\frac {\sin \left (a+b\,x\right )\,\left (6\,c\,d^2-b^2\,c^3\right )}{b^3}-\frac {3\,\cos \left (a+b\,x\right )\,\left (2\,d^3-b^2\,c^2\,d\right )}{b^4}+\frac {d^3\,x^3\,\sin \left (a+b\,x\right )}{b}-\frac {3\,x\,\sin \left (a+b\,x\right )\,\left (2\,d^3-b^2\,c^2\,d\right )}{b^3}+\frac {6\,c\,d^2\,x\,\cos \left (a+b\,x\right )}{b^2}+\frac {3\,c\,d^2\,x^2\,\sin \left (a+b\,x\right )}{b} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 1.19, size = 202, normalized size = 2.89 \[ \begin {cases} \frac {c^{3} \sin {\left (a + b x \right )}}{b} + \frac {3 c^{2} d x \sin {\left (a + b x \right )}}{b} + \frac {3 c d^{2} x^{2} \sin {\left (a + b x \right )}}{b} + \frac {d^{3} x^{3} \sin {\left (a + b x \right )}}{b} + \frac {3 c^{2} d \cos {\left (a + b x \right )}}{b^{2}} + \frac {6 c d^{2} x \cos {\left (a + b x \right )}}{b^{2}} + \frac {3 d^{3} x^{2} \cos {\left (a + b x \right )}}{b^{2}} - \frac {6 c d^{2} \sin {\left (a + b x \right )}}{b^{3}} - \frac {6 d^{3} x \sin {\left (a + b x \right )}}{b^{3}} - \frac {6 d^{3} \cos {\left (a + b x \right )}}{b^{4}} & \text {for}\: b \neq 0 \\\left (c^{3} x + \frac {3 c^{2} d x^{2}}{2} + c d^{2} x^{3} + \frac {d^{3} x^{4}}{4}\right ) \cos {\relax (a )} & \text {otherwise} \end {cases} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________